home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1994 #2 / Monster Media No. 2 (Monster Media)(1994).ISO / prog_gen / xv_pc16a.zip / EXCLUSIV.INC < prev    next >
Text File  |  1994-04-23  |  865b  |  31 lines

  1. {
  2. Windows with exclusive access in the XView-PC interface
  3. By Antonio Carlos Moreirao de Queiroz - acmq@coe.ufrj.br
  4. Version 1.0 - 10/04/94
  5.  
  6. Procedure similar to "open_window", but with the control returning to the
  7. calling point when the window "w" is closed.
  8. The window "w" must be initially closed, and its "callbacks" cannot open
  9. windows that are already open.
  10. Use in simple warnings to the user that require immediate response.
  11. Try to use "open_window" instead of this procedure whenever possible.
  12. }
  13.  
  14. PROCEDURE open_exclusive_window(w:Xv_opaque);
  15. VAR
  16.   temp_w:Xv_opaque;
  17.   temp:BOOLEAN;
  18.   VP:ViewPortType;
  19. BEGIN
  20.   temp_w:=active_w;
  21.   temp:=wallpaper;
  22.   wallpaper:=TRUE;
  23.   active_w:=nil;
  24.   GetViewSettings(VP);
  25.   xv_main_loop(w);
  26.   xv_end:=FALSE;
  27.   active_w:=temp_w;
  28.   wallpaper:=temp;
  29.   WITH VP DO SetViewPort(x1,y1,x2,y2,Clip)
  30. END;
  31.